import request from "@/utils/request";

const modules = {
  //创建交易
  createTrade: (data) =>
    request({
      method: "post",
      data,
      url: "/trade/create",
    }),
  //支付
  pay: (data) =>
    request({
      method: "post",
      data,
      url: "/payment/pay",
    }),
  //取消支付
  canclePay: (data) =>
    request({
      method: "post",
      data,
      url: "/payment/cancel",
    }),
};

export default modules;
